# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=py3-email-validator
_pkgname=python-email-validator
pkgver=1.1.1
pkgrel=0
pkgdesc="A robust email syntax and deliverability validation library"
url="https://github.com/JoshData/python-email-validator"
arch="noarch"
license="CC0-1.0"
depends="py3-dnspython py3-idna"
makedepends="py3-setuptools"
checkdepends="py3-pytest"
source="$pkgname-$pkgver.tar.gz::https://github.com/JoshData/$_pkgname/archive/v$pkgver.tar.gz"
builddir=$srcdir/$_pkgname-$pkgver

replaces="py-email-validator" # Backwards compatibility
provides="py-email-validator=$pkgver-r$pkgrel" # Backwards compatibility

build() {
	python3 setup.py build
}

check() {
	PYTHONPATH="$PWD/build/lib" py.test-3
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="fb4dc5b728adca6041129aa3eecb3efbb358ecf47bf383737936132df7b24c3b9e47e56918d375d8eb4a2535d56ce22c9e03dc126dafd8894911b43fe30f5162  py3-email-validator-1.1.1.tar.gz"
